
use Milexp.dta, clear


xtset state year


//COW data
//milexp

xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  usallydef  lnUStroops lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg01


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  usallydef lnUStroops deftroop lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg02


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  usallyasy  lnUStroops lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg03


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  usallyasy lnUStroops asytroop lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg04


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  atopdefense  lnUStroops lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg05


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  atopdefense lnUStroops adeftroop lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg06


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  atopasymm  lnUStroops lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg07


xtpcse lmilex  peaceyrs democ numstate lnrgdp lnfoes  atopasymm lnUStroops aasytroop lmilex1 i.year region1 region2 region3 region4 region5 region6, correlation(ar1) hetonly
est sto reg08

esttab reg0* using res_milexp.txt , label scalars( r2_o) nonumbers mtitles("Def" "def-interaction" "Asy" "asy-interaction" "Def" "def-interaction" "Asy" "asy-interaction") drop(19* 20*) se r2  star(* 0.05 ** 0.01 *** 0.001) b(3) replace

